package com.bkgy.controller.technology.entity.dto;

import lombok.Data;

@Data
public class RollInfo implements Comparable<RollInfo> {
    private String title;
    private Integer count;

    public RollInfo(String title, Integer count) {
        this.title = title;
        this.count = count;
    }

    @Override
    public int compareTo(RollInfo rollInfo) {
        if (this.count > rollInfo.count)
            return -1;
        else if (this.count < rollInfo.count)
            return 1;
        else return 0;
    }
}
